﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Automation;

namespace Dtf.Core.Controls
{
    public class ComboBox : UIItem
    {
        public ComboBox(UIItem uiItem)
            : base(uiItem)
        {
        }

        public void Select()
        {
            //SelectionPattern parttern = base.Element.GetCurrentPattern(SelectionPattern.Pattern) as SelectionPattern;
            //parttern.Current.GetSelection()[0].
            //parttern.
        }

        public void Expand()
        {
            ExpandCollapsePattern parttern = base.Element.GetCurrentPattern(ExpandCollapsePattern.Pattern) as ExpandCollapsePattern;
            parttern.Expand();
        }

        public void Collapse()
        {
            ExpandCollapsePattern parttern = base.Element.GetCurrentPattern(ExpandCollapsePattern.Pattern) as ExpandCollapsePattern;
            parttern.Collapse();
        }

        public ExpandCollapseState ExpandCollapseState()
        {
            ExpandCollapsePattern parttern = base.Element.GetCurrentPattern(ExpandCollapsePattern.Pattern) as ExpandCollapsePattern;
            return parttern.Current.ExpandCollapseState;
            
        }
    }
}
